package spring.in.action.chapter_01;

import org.springframework.context.support.ClassPathXmlApplicationContext;

import spring.in.action.chapter_01.Interface.ICoder;

public class CoderMain
{

    public static void main(String[] args)
    {
        ClassPathXmlApplicationContext lApplicationContext = new ClassPathXmlApplicationContext(
                "chapter_01.xml");

        ICoder lCoder = lApplicationContext.getBean(ICoder.class);
        lCoder.coding();

        lCoder = (ICoder) lApplicationContext.getBean("coder");
        lCoder.coding();

        lApplicationContext.close();
    }

}
